import req from '../fetch/index.js'

const config = {
  // 获取表格信息
    getTableData: {
        url: '/pc/store/listStore',
        method:'post'
  },
  // 新增门店信息
  addStore: {
    url: '/pc/store/addStore',
    method:"post"
  },
  // 删除门店
  deleteStore: {
    url: '/pc/store/deleteStore',
    method:'post'
  },
  // 查询修改门店
  getStore: {
    url: '/pc/store/getStore',
    method:'post'
  },
  
  // 修改门店
  updateStore:{
    url: '/pc/store/updateStore',
    method:'post'
  },
  // 查询门店详情
  getStoreDetail: {
    url: '/pc/store/getStoreDetail',
    method:'post'
  },
  // 查询省下拉框接口
  listProvince: {
    url: '/pc/dictory/listProvince',
    method:'post'
  },
  // 查询市数据
  listCity: {
    url: '/pc/dictory/listCity',
    method:'post'
  },
  // 查询区
  listDistrict: {
    url: '/pc/dictory/listDistrict',
    method:'post'
  },
  // 查询未绑定门店店长编号
  selectManger: {
    url: '/pc/user/selectManager',
    method:'post'
  }
  
}

const request = function (funcName, requestParam) {
  return req(config[funcName].url, config[funcName].method, requestParam, {}, config[funcName].fileConfig)
}
export default request
